package com.lyshop.jinxiang.utils;

import android.widget.ImageView;


import com.lyshop.jinxiang.R;

/**
 * 勋章类
 */
public class MedalUtils {

    public static void setUserCenterLevelTag(int level, ImageView iv) {
        if (level == 1) {
            iv.setImageResource(R.drawable.img_level_tag_1);
        } else if (level == 2) {
            iv.setImageResource(R.drawable.img_level_tag_2);
        } else if (level == 3) {
            iv.setImageResource(R.drawable.img_level_tag_3);
        } else if (level == 4) {
            iv.setImageResource(R.drawable.img_level_tag_4);
        } else if (level == 5) {
            iv.setImageResource(R.drawable.img_level_tag_5);
        } else if (level == 6) {
            iv.setImageResource(R.drawable.img_level_tag_6);
        } else if (level >= 7) {
            iv.setImageResource(R.drawable.img_level_tag_7);
        }
    }

    public static String getUserLevelName(int level) {
        if (level == 1) {
            return "大众会员";
        } else if (level == 2) {
            return "青铜会员";
        } else if (level == 3) {
            return "白银会员";
        } else if (level == 4) {
            return "黄金会员";
        } else if (level == 5) {
            return "铂金会员";
        } else if (level == 6) {
            return "钻石会员";
        } else if (level >= 7) {
            return "黑钻会员";
        }
        return "大众会员";
    }

}
